package cn.com.nes.site.controller.crm.opportunity.vo;

import cn.com.nes.site.entity.vo.PageVO;
import cn.com.nes.site.service.crm.opportunity.bo.OpportunityFileBO;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.hibernate.validator.constraints.NotEmpty;
import org.springframework.beans.BeanUtils;

@ApiModel(value = "查询商机文件入参模型")
@Data
public class GetOpportunityFilePageVO extends PageVO {

    @ApiModelProperty(value = "商机id", required = true)
    @NotEmpty(message = "商机id")
    private String opportunityId;

    public OpportunityFileBO convertToBo() {
        OpportunityFileBO bo = new OpportunityFileBO();
        BeanUtils.copyProperties(this, bo);
        return bo;
    }
}
